/*
 * Copyright (C) 2011 The Code Bakers
 * Authors: Cleuton Sampaio e Francisco Rodrigues
 * e-mail: thecodebakers@gmail.com
 * Project: http://code.google.com/p/layout-exercise/
 * Site: http://thecodebakers.blogspot.com
 *
 * Licensed under the GNU GPL, Version 3.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://gplv3.fsf.org/
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 * 
 * @author Cleuton Sampaio e Francisco Rogrigues - thecodebakers@gmail.com
 */

package br.com.thecodebakers.layouts;

import android.app.Activity;
import android.content.res.Resources;
import android.os.Bundle;
import android.widget.ArrayAdapter;
import android.widget.ListView;

public class ListaComBarra extends Activity {
	private static final String TAG = "main";
    private ListView listView;
	private String [] lv_arr = new String[3];
	private ArrayAdapter<String> adapter = null;

	@Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.listascombarra);
        listView = (ListView)findViewById(android.R.id.list);
        listView.setTextFilterEnabled(true);
    }

    @Override
	protected void onStart() {
    	super.onStart();
    	Resources res = this.getResources();
    	lv_arr[0] = res.getString(R.string.lista1);
    	lv_arr[1] = res.getString(R.string.lista2);
    	lv_arr[2] = res.getString(R.string.lista3);
        adapter = new ArrayAdapter<String>(this,android.R.layout.simple_list_item_1, lv_arr);
        listView.setAdapter(adapter);
	}


}
